package com.jiazhong.ditest;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Arrays;

/**
 * @Auther:shuXin
 */
@AllArgsConstructor
@NoArgsConstructor
@Data
public class Emp {
    //工作的部门，隶属于的部门
    private Dept dept;
    private String ename;
    private Integer age;

    //添加员工爱好的属性
    private String[] hobbies;

    public void work() {
        System.out.println(ename + " is working..." + age + " years old" + dept + "...");
        System.out.println(Arrays.toString(hobbies));
    }
}
